package com.kakarote.ids.provider.entity.VO;

import java.time.LocalDateTime;
import java.util.List;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.kakarote.common.entity.SimpleDept;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

@ApiModel("员工VO")
public class UserVO {
	@ApiModelProperty("用户ID")
	@JsonSerialize(using = ToStringSerializer.class)
	private Long userId;
	@ApiModelProperty("用户名")
	private String username;
	@ApiModelProperty("昵称")
	private String nickname;
	@ApiModelProperty("用户头像")
	private String userImg;
	@ApiModelProperty("手机号")
	private String mobile;
	@ApiModelProperty("邮箱")
	private String email;
	@ApiModelProperty("状态 0 禁用,1 正常,2 未激活")
	private Integer status;
	@ApiModelProperty("性别 0 未知 1 男 2 女")
	private Integer sex;
	@ApiModelProperty("用户个人说明")
	private String userText;

	public void setUserId(Long userId) {
		this.userId = userId;
	}

	@ApiModelProperty("是否是负责人（0否 1是）")
	private Integer isLeader;
	@ApiModelProperty("登录次数")
	private Integer loginsCount;
	@ApiModelProperty("最后登录时间")
	private LocalDateTime lastLoginTime;
	@ApiModelProperty("最后登录应用")
	private String appName;
	@ApiModelProperty("部门集合")
	private List<SimpleDept> deptList;
	@ApiModelProperty("上级ID")
	private Long parentId;
	@ApiModelProperty("上级名称")
	private String parentName;
	@ApiModelProperty("角色ID")
	private String roleId;
	@ApiModelProperty("角色名称")
	private String roleName;

	public void setUsername(String username) {
		this.username = username;
	}

	public void setNickname(String nickname) {
		this.nickname = nickname;
	}

	public void setUserImg(String userImg) {
		this.userImg = userImg;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public void setSex(Integer sex) {
		this.sex = sex;
	}

	public void setUserText(String userText) {
		this.userText = userText;
	}

	public void setIsLeader(Integer isLeader) {
		this.isLeader = isLeader;
	}

	public void setLoginsCount(Integer loginsCount) {
		this.loginsCount = loginsCount;
	}

	public void setLastLoginTime(LocalDateTime lastLoginTime) {
		this.lastLoginTime = lastLoginTime;
	}

	public void setAppName(String appName) {
		this.appName = appName;
	}

	public void setDeptList(List<SimpleDept> deptList) {
		this.deptList = deptList;
	}

	public void setParentId(Long parentId) {
		this.parentId = parentId;
	}

	public void setParentName(String parentName) {
		this.parentName = parentName;
	}

	public void setRoleId(String roleId) {
		this.roleId = roleId;
	}

	public void setRoleName(String roleName) {
		this.roleName = roleName;
	}

	public boolean equals(Object o) {
		if (o == this)
			return true;
		if (!(o instanceof UserVO))
			return false;
		UserVO other = (UserVO) o;
		if (!other.canEqual(this))
			return false;
		Object this$userId = getUserId(), other$userId = other.getUserId();
		if ((this$userId == null) ? (other$userId != null) : !this$userId.equals(other$userId))
			return false;
		Object this$status = getStatus(), other$status = other.getStatus();
		if ((this$status == null) ? (other$status != null) : !this$status.equals(other$status))
			return false;
		Object this$sex = getSex(), other$sex = other.getSex();
		if ((this$sex == null) ? (other$sex != null) : !this$sex.equals(other$sex))
			return false;
		Object this$isLeader = getIsLeader(), other$isLeader = other.getIsLeader();
		if ((this$isLeader == null) ? (other$isLeader != null) : !this$isLeader.equals(other$isLeader))
			return false;
		Object this$loginsCount = getLoginsCount(), other$loginsCount = other.getLoginsCount();
		if ((this$loginsCount == null) ? (other$loginsCount != null) : !this$loginsCount.equals(other$loginsCount))
			return false;
		Object this$parentId = getParentId(), other$parentId = other.getParentId();
		if ((this$parentId == null) ? (other$parentId != null) : !this$parentId.equals(other$parentId))
			return false;
		Object this$username = getUsername(), other$username = other.getUsername();
		if ((this$username == null) ? (other$username != null) : !this$username.equals(other$username))
			return false;
		Object this$nickname = getNickname(), other$nickname = other.getNickname();
		if ((this$nickname == null) ? (other$nickname != null) : !this$nickname.equals(other$nickname))
			return false;
		Object this$userImg = getUserImg(), other$userImg = other.getUserImg();
		if ((this$userImg == null) ? (other$userImg != null) : !this$userImg.equals(other$userImg))
			return false;
		Object this$mobile = getMobile(), other$mobile = other.getMobile();
		if ((this$mobile == null) ? (other$mobile != null) : !this$mobile.equals(other$mobile))
			return false;
		Object this$email = getEmail(), other$email = other.getEmail();
		if ((this$email == null) ? (other$email != null) : !this$email.equals(other$email))
			return false;
		Object this$userText = getUserText(), other$userText = other.getUserText();
		if ((this$userText == null) ? (other$userText != null) : !this$userText.equals(other$userText))
			return false;
		Object this$lastLoginTime = getLastLoginTime(), other$lastLoginTime = other.getLastLoginTime();
		if ((this$lastLoginTime == null) ? (other$lastLoginTime != null)
				: !this$lastLoginTime.equals(other$lastLoginTime))
			return false;
		Object this$appName = getAppName(), other$appName = other.getAppName();
		if ((this$appName == null) ? (other$appName != null) : !this$appName.equals(other$appName))
			return false;
		List<SimpleDept> this$deptList = (List<SimpleDept>) getDeptList(),
				other$deptList = (List<SimpleDept>) other.getDeptList();
		if ((this$deptList == null) ? (other$deptList != null) : !this$deptList.equals(other$deptList))
			return false;
		Object this$parentName = getParentName(), other$parentName = other.getParentName();
		if ((this$parentName == null) ? (other$parentName != null) : !this$parentName.equals(other$parentName))
			return false;
		Object this$roleId = getRoleId(), other$roleId = other.getRoleId();
		if ((this$roleId == null) ? (other$roleId != null) : !this$roleId.equals(other$roleId))
			return false;
		Object this$roleName = getRoleName(), other$roleName = other.getRoleName();
		return !((this$roleName == null) ? (other$roleName != null) : !this$roleName.equals(other$roleName));
	}

	protected boolean canEqual(Object other) {
		return other instanceof UserVO;
	}

	public int hashCode() {
		int PRIME = 59;
		int result = 1;
		Object $userId = getUserId();
		result = result * 59 + (($userId == null) ? 43 : $userId.hashCode());
		Object $status = getStatus();
		result = result * 59 + (($status == null) ? 43 : $status.hashCode());
		Object $sex = getSex();
		result = result * 59 + (($sex == null) ? 43 : $sex.hashCode());
		Object $isLeader = getIsLeader();
		result = result * 59 + (($isLeader == null) ? 43 : $isLeader.hashCode());
		Object $loginsCount = getLoginsCount();
		result = result * 59 + (($loginsCount == null) ? 43 : $loginsCount.hashCode());
		Object $parentId = getParentId();
		result = result * 59 + (($parentId == null) ? 43 : $parentId.hashCode());
		Object $username = getUsername();
		result = result * 59 + (($username == null) ? 43 : $username.hashCode());
		Object $nickname = getNickname();
		result = result * 59 + (($nickname == null) ? 43 : $nickname.hashCode());
		Object $userImg = getUserImg();
		result = result * 59 + (($userImg == null) ? 43 : $userImg.hashCode());
		Object $mobile = getMobile();
		result = result * 59 + (($mobile == null) ? 43 : $mobile.hashCode());
		Object $email = getEmail();
		result = result * 59 + (($email == null) ? 43 : $email.hashCode());
		Object $userText = getUserText();
		result = result * 59 + (($userText == null) ? 43 : $userText.hashCode());
		Object $lastLoginTime = getLastLoginTime();
		result = result * 59 + (($lastLoginTime == null) ? 43 : $lastLoginTime.hashCode());
		Object $appName = getAppName();
		result = result * 59 + (($appName == null) ? 43 : $appName.hashCode());
		List<SimpleDept> $deptList = (List<SimpleDept>) getDeptList();
		result = result * 59 + (($deptList == null) ? 43 : $deptList.hashCode());
		Object $parentName = getParentName();
		result = result * 59 + (($parentName == null) ? 43 : $parentName.hashCode());
		Object $roleId = getRoleId();
		result = result * 59 + (($roleId == null) ? 43 : $roleId.hashCode());
		Object $roleName = getRoleName();
		return result * 59 + (($roleName == null) ? 43 : $roleName.hashCode());
	}

	public String toString() {
		return "UserVO(userId=" + getUserId() + ", username=" + getUsername() + ", nickname=" + getNickname()
				+ ", userImg=" + getUserImg() + ", mobile=" + getMobile() + ", email=" + getEmail() + ", status="
				+ getStatus() + ", sex=" + getSex() + ", userText=" + getUserText() + ", isLeader=" + getIsLeader()
				+ ", loginsCount=" + getLoginsCount() + ", lastLoginTime=" + getLastLoginTime() + ", appName="
				+ getAppName() + ", deptList=" + getDeptList() + ", parentId=" + getParentId() + ", parentName="
				+ getParentName() + ", roleId=" + getRoleId() + ", roleName=" + getRoleName() + ")";
	}

	public Long getUserId() {
		return this.userId;
	}

	public String getUsername() {
		return this.username;
	}

	public String getNickname() {
		return this.nickname;
	}

	public String getUserImg() {
		return this.userImg;
	}

	public String getMobile() {
		return this.mobile;
	}

	public String getEmail() {
		return this.email;
	}

	public Integer getStatus() {
		return this.status;
	}

	public Integer getSex() {
		return this.sex;
	}

	public String getUserText() {
		return this.userText;
	}

	public Integer getIsLeader() {
		return this.isLeader;
	}

	public Integer getLoginsCount() {
		return this.loginsCount;
	}

	public LocalDateTime getLastLoginTime() {
		return this.lastLoginTime;
	}

	public String getAppName() {
		return this.appName;
	}

	public List<SimpleDept> getDeptList() {
		return this.deptList;
	}

	public Long getParentId() {
		return this.parentId;
	}

	public String getParentName() {
		return this.parentName;
	}

	public String getRoleId() {
		return this.roleId;
	}

	public String getRoleName() {
		return this.roleName;
	}
}
